package com.jy.control;

import com.jy.entity.Students;
import com.jy.mapper.StudentMapper;
import com.jy.service.IStudentSerivce;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

/**
 * 类名：
 * 作者：WF
 * 功能：
 */
@RestController
@RequestMapping("/student")
public class StudentController {
	@Autowired
	private IStudentSerivce studentSerivce;
	// 1. 查询所有学生列表
	@GetMapping("/list")
	public List<Students> list() {
		return studentSerivce.list();
	}
}
